/*
 * @Author: your name
 * @Date: 2021-06-22 10:52:25
 * @LastEditTime: 2021-06-22 15:53:58
 * @LastEditors: Please set LastEditors
 * @Description: In User Settings Edit
 * @FilePath: \rpcMsg\rpcinterface\client\msg\msg.go
 */
package msg

import (
	"context"

	"git.900sui.cn/kc/rpcinterface/client"
	"git.900sui.cn/kc/rpcinterface/interface/msg"
)

type Msg struct {
	client.Baseclient
}

//Init Init
func (m *Msg) Init() *Msg {
	m.ServiceName = "rpc_msg"
	m.ServicePath = "Msg"
	return m
}

//推送商户自定义消息
func (m *Msg) PushCustomMsg(ctx context.Context, args *msg.PushCustomMsgArgs, reply *bool) (err error) {
	return m.Call(ctx, "PushCustomMsg", args, reply)
}

//推送系统自定义消息
func (m *Msg) PushSystemMsg(ctx context.Context, args *msg.PushSystemMsgArgs, reply *bool) (err error) {
	return m.Call(ctx, "PushSystemMsg", args, reply)
}

//用户-获取消息类型列表
func (m *Msg) GetMsgTypes(ctx context.Context, args *msg.MsgTypeArgs, reply *[]msg.MsgTypeReply) (err error) {
	return m.Call(ctx, "GetMsgTypes", args, reply)
}

//用户-获取消息列表
func (m *Msg) GetMsgListByUser(ctx context.Context, args *msg.MsgListByUserArgs, reply *msg.MsgListByUserReplyList) (err error) {
	return m.Call(ctx, "GetMsgListByUser", args, reply)
}

//用户-获取消息详情
func (m *Msg) FindMsgInfoById(ctx context.Context, args *msg.MsgInfoByIdArgs, reply *msg.MsgInfoByIdReply) (err error) {
	return m.Call(ctx, "FindMsgInfoById", args, reply)
}

//更新消息状态
func (m *Msg) UpdateMsgReadedStatusByUser(ctx context.Context, args *msg.UpdateMsgReadedStatusArgs, reply *bool) (err error) {
	return m.Call(ctx, "UpdateMsgReadedStatusByUser", args, reply)
}
